﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

using My_TV_Manager.Model;
using My_TV_Manager.View.MenuBar;

namespace My_TV_Manager.View.ContentPanel
{
    [System.ComponentModel.DesignerCategory("")]

    public class ManageTab : InnerTabbedContainer
    {
        private Controller controller;

        // Constructor using controller for program data
        public ManageTab(Size size, int index, Controller controller) 
            : base(size)
        {
            this.controller = controller;

            // Name the tabs and initialize new panel for each tab
            var buttons = new List<string>()
            {
                "Start",
                "Television News",
                "Upcoming Episodes"
            };

            // Add the content panels which correspond to the inner menubar
            for (int i = 0; i < buttons.Count; i++)
            {
                contentPanels.Add(new Panel());
            }
            this.Panel2.Controls.Add(contentPanels[0]);
            this.Panel2.BackColor = Settings.Colors.Get(index);

            // Initialize the menu bar with the new menu options
            innerMenuBar = new InnerMenuBar(this,
                                            this.Panel1.ClientSize,
                                            buttons,
                                            index);
            this.Panel1.Controls.Add(innerMenuBar);
        }
    }
}
